package com.verisette.ncos.service.card.bizunit;

import java.util.Date;
import java.util.List;
import java.util.Map;

import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Required;

import org.corp.agi.common.exception.ProcessException;
import org.corp.agi.service.bean.ProcessContext;
import org.corp.agi.service.bizunit.CommonBusinessUnit;
import com.verisette.ncos.common.CommonUtil;
import com.verisette.ncos.common.ProjectConstant;
import com.verisette.ncos.persistence.dao.AuditLogDAO;
import com.verisette.ncos.persistence.dao.CardDAO;
import com.verisette.ncos.persistence.domain.CustomLogAuditLog;
import com.verisette.ncos.persistence.domain.MasterTemplate;
import com.verisette.ncos.persistence.domain.MasterUserProfile;

import com.verisette.ncos.web.master.bean.AuditLogSearchBean;

public class InquiryCardTemplateByUspIdBU extends CommonBusinessUnit {

	private Logger logger = Logger.getLogger(InquiryCardTemplateByUspIdBU.class);
	
	private CardDAO cardDAO;
	@Required
	@Autowired
	public void setCardDAO(CardDAO cardDAO) {
		this.cardDAO = cardDAO;
	}
	
	@Override
	public void execute(ProcessContext processContext) throws ProcessException {
		if(logger.isInfoEnabled()) logger.info( this.getClass().getSimpleName() + ": execute" );
		List<MasterTemplate> cardTemplateList = cardDAO.inquiryMasterTemplateByUspId((MasterUserProfile)processContext.getUserBean());
		logger.debug("--> resultList size : " + cardTemplateList.size());
		processContext.setValueObject(cardTemplateList);
		
	}
	
}
